package com.cc8w.home.controller;

import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/home/index")
public class IndexController {

    @RequestMapping("/index/{id}/{name}")
    public String index(@PathVariable("id") Integer id,@PathVariable("name") String name){
        System.out.println(id+name);

        return id.toString()+name;
    }

    //post怎么传递对象？
    @PostMapping("/saveuser")
    public String saveUser(){
        return null;
    }

    @DeleteMapping("/deleteuser/{id}")
    public String deleteUser(){
        return null;
    }

    @PutMapping("/updateuser")
    public String updateUser(){
        return null;
    }

    @GetMapping("/getuser/{id}")
    public String getUser(){
        return null;
    }



}
